<template>
  <div class="notation-char">
    {{ value }}
    <div class="notation-level-dot" :class="level">·</div>
  </div>
</template>
<script>
import { computed } from 'vue'
export default {
  name: 'NotationChar',
  props: {
    char: String,
  },
  setup(props) {
    // const innerChar = toRefs(props.char)
    // console.log(props.char)
    const level = computed(() => props.char.split('-')[0])
    const value = computed(() => props.char.split('-')[1])
    return {
      level,
      value,
    }
  },
}
</script>
<style lang="less" scoped>
.notation-char {
  position: relative;
  display: inline-block;
  height: 16px;
  width: 8px;
  text-align: center;
  .notation-level-dot {
    position: absolute;
    height: 0;
    width: 8px;
    line-height: 0;
    font-weight: 600;
    // font-size: ;
    &.low {
      top: 125%;
    }
    &.mid {
      display: none;
    }
    &.high {
      bottom: 100%;
    }
  }
}
</style>
